home *** CD-ROM | disk | FTP | other *** search
/ PC Welt 2001 September / PC-WELT 9-2001.ISO / software / hw / brennen / flask_src.exe / Audio / Resampler / stdefs.h < prev   
Encoding:
C/C++ Source or Header  |  2000-05-06  |  1.8 KB  |  77 lines

  1. /* 
  2.  *  stdefs.h 
  3.  * 
  4.  *  Original code from Julius O. Smith III< jos@ccrma.stanford.edu>
  5.  *
  6.  *    Copyright (C) Alberto Vigata - January 2000
  7.  *
  8.  *  This file is part of FlasKMPEG, a free MPEG to MPEG/AVI converter
  9.  *    
  10.  *  FlasKMPEG is free software; you can redistribute it and/or modify
  11.  *  it under the terms of the GNU General Public License as published by
  12.  *  the Free Software Foundation; either version 2, or (at your option)
  13.  *  any later version.
  14.  *   
  15.  *  FlasKMPEG is distributed in the hope that it will be useful,
  16.  *  but WITHOUT ANY WARRANTY; without even the implied warranty of
  17.  *  MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
  18.  *  GNU General Public License for more details.
  19.  *   
  20.  *  You should have received a copy of the GNU General Public License
  21.  *  along with GNU Make; see the file COPYING.  If not, write to
  22.  *  the Free Software Foundation, 675 Mass Ave, Cambridge, MA 02139, USA. 
  23.  *
  24.  */
  25.  
  26. #ifndef _STDEFS_H
  27. #define _STDEFS_H
  28.  
  29. #ifndef TRUE
  30. #define TRUE  1
  31. #endif
  32.  
  33. #ifndef FALSE
  34. #define FALSE 0
  35. #endif
  36.  
  37. #ifndef PI
  38. #define PI (3.14159265358979232846)
  39. #endif
  40.  
  41. #ifndef PI2
  42. #define PI2 (6.28318530717958465692)
  43. #endif
  44.  
  45. #define D2R (0.01745329348)          /* (2*pi)/360 */
  46. #define R2D (57.29577951)            /* 360/(2*pi) */
  47.  
  48. #ifndef MAX
  49. #define MAX(x,y) ((x)>(y) ?(x):(y))
  50. #endif
  51. #ifndef MIN
  52. #define MIN(x,y) ((x)<(y) ?(x):(y))
  53. #endif
  54.  
  55. #ifndef ABS
  56. #define ABS(x)   ((x)<0   ?(-(x)):(x))
  57. #endif
  58.  
  59. #ifndef SGN
  60. #define SGN(x)   ((x)<0   ?(-1):((x)==0?(0):(1)))
  61. #endif
  62.  
  63. //typedef char           BOOL;
  64. typedef short          HRWORD;
  65. typedef unsigned short UHRWORD;
  66. typedef int            RWORD;
  67. typedef unsigned int   URWORD;
  68.  
  69. #define MAX_HRWORD (32767)
  70. #define MIN_HRWORD (-32768)
  71.  
  72.  
  73. #define INLINE inline
  74.  
  75.  
  76. #endif /* _STDEFS_H */
  77.